<!DOCTYPE html>
<html>

	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		<meta name="renderer" content="webkit">
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
		<meta http-equiv="Pragma" content="no-cache" />
		<meta http-equiv="Cache-Control" content="no-cache" />
		<meta http-equiv="Expires" content="0" />
		<link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
		<title>Smart平台-登录</title>
		<link rel="stylesheet" href="smart-ui/src/assets/css/ng-common/ng-reset.css" />
		<link rel="stylesheet" href="smart-ui/src/assets/css/ng-common/ng-common.css" />
		<link rel="stylesheet" href="smart-ui/src/assets/css/ng-common/ng-components.css" />
		<!-- login style -->
		<link rel="stylesheet" href="smart-ui/src/assets/css/demo.css" />
		<link rel="stylesheet" href="smart-ui/src/assets/css/login_test.css" />
	</head>

	<body oncontextmenu="return false;">
		<div class="page_blk">
			<!--顶线-->
			<div class="top_line">
				<div class="top_line_left"></div>
				<div class="top_line_right"></div>
			</div>
			<!--主区域-->
			<div class="main_blk">

				<div class="main_form">
					<div class="form_blk">

						<form autocomplete="off" id="formw">
							
							
							
							
							
							<!--  登录页面   -->
							<div class="page-w">
								<div class="tit_login">
									<!-- <img src="devops/src/assets/img/loginx.png"/> -->
								</div>

								<div class="page-w2">
									<div class="login-panel">
									<div class="loginbar">

										<div class="loginbar-right">
											
											<span class="span1w">
												<img src="smart-ui/src/assets/img/admin.png">
											</span>
											<span class="span2w">账号:</span>
											
											<input name="l_u" class="userName" type="text" autocomplete="off"  onfocus="this.placeholder=''"/>
										</div>
									</div>
									
									<div class="msg-w">
										
										<div class="UppercaseLock msgx-w hide">
											<span class="tips">大写锁定已开启</span>
										</div>
									</div>
									

									<div class="msg-w"></div>

									
									<div class="msg-w2">
										
										<div id="loginTips" class="msgx-w hide">
											<span class="tips">账号、密码或验证码错误.</span>
											
											<span id="timer" class="Countdown"></span>											
										</div>
									</div>
									

									<div class="loginbar-w">
										<input type="button" value="登录" class="loginbar-w2 login_bt"/>
									</div>
									</div>
								</div>
							</div>


						</form>

					</div>
				</div>

			</div>
			<!--版权-->
			<div class="copyright_login"></div>
			<div class="logout hide"></div>

			<div class="winw" style="display: none;"></div>
			<div class="winw-w" style="display: none;">
				<div class="alertw">
					<a class="d1" target="_blank" href="http://www.firefox.com.cn/"></a>
					<a class="d2" target="_blank" href="https://support.microsoft.com/zh-cn/help/17621/internet-explorer-downloads"></a>
					<a class="d3" target="_blank" href="http://www.google.cn/intl/zh-CN/chrome/browser/"></a>
				</div>
			</div>
		</div>
		<script>
			//解决ie下console.log()报错问题
			window.console = window.console || (function() {
				var c = {};
				c.log = c.warn = c.debug = c.info = c.error = c.time = c.dir = c.profile = c.clear = c.exception = c.trace = c.assert = function() {};
				return c;
			})();
			/**
			 * 每次上线前请修改这个版本号解决上线后资源缓存问题
			 * */
			window.Args = '20170815';
			window.UEDITOR_HOME_URL = 'smart-ui/src/assets/lib/ueditor/';
		</script>
		<!-- js -->
		<script src="smart-ui/src/js/common/requirejsMain_singlepage.js"></script>
		<script src="smart-ui/src/assets/lib/requirejs/requirejs.min.js"></script>
		<script type="text/javascript">

			require(['Util', 'cookie', 'base64', 'underscore','dialog', 'jquery.md5'], function(Util, $cookie, Base64, Dialog, underscore) {
                    $('.loginbar-w2').click(function() {
                        if($('.userName').val()!==""){
                            Util.ajax.getJson("http://192.168.0.104:8091/ai-management/login/login?userAccount="+$.trim($('.userName').val()),{} ,function(result, isok){
                                if (result.returnCode === "0000") {
                                    if(result.beans.userId){
                                        $cookie.set("userId",result.beans.userId);
                                        $cookie.set("userAccount",result.beans.userAccount);
                                        window.location.href='http://localhost:8892/?menuShow=dfvbn#&loginUserAccount='+result.beans.userId;
									}

                                } else {
                                    new Dialog({
                                        mode: 'confirm', // 对话框模式，默认normal标准|confirm浮动层|confirm确认对话框
                                        title: '提示',
                                        width: 300, //对话框宽度，可选项。normal默认值为600，confirm默认值为300，tips默认值为240
                                        height: 120, //对话框高度，可选项。normal默认值为400，confirm默认值为180，tips默认值为80
                                        cancelDisplay: false, //是否显示取消按钮（强制执行，可在confirm模式下生效），可选项。 默认true(显示)
                                        modal: true,
                                        content: '<div style="text-align:center;margin-top:50px">' + result.returnMessage + '</div>'// 对话框内容，可以是字符串、html片段、或dom对象,默认为loading状态（点组成的圈）
                                    });
                                }

                            });
						}else{
                            return false
						}

                    })





				//END
			});
		</script>
		<!--   浏览器兼容问题     -->
		<script>
			function myBrowser() {
				var userAgent = navigator.userAgent; //取得浏览器的userAgent字符串
				var isOpera = userAgent.indexOf("Opera") > -1; //判断是否Opera浏览器
				var isIE = userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1 && !isOpera; //判断是否IE浏览器
				//		    var isFF = userAgent.indexOf("Firefox") > -1; //判断是否Firefox浏览器
				var isSafari = userAgent.indexOf("Safari") > -1; //判断是否Safari浏览器
				if(isIE) {
					var IE5 = IE55 = IE6 = IE7 = IE8 = IE9 = IE10 = false;
					var reIE = new RegExp("MSIE (\\d+\\.\\d+);");
					reIE.test(userAgent);
					var fIEVersion = parseFloat(RegExp["$1"]);
					IE55 = fIEVersion == 5.5;
					IE6 = fIEVersion == 6.0;
					IE7 = fIEVersion == 7.0;
					IE8 = fIEVersion == 8.0;
					IE9 = fIEVersion == 9.0;
					IE10 = fIEVersion == 10.0;
					if(IE55) {
						return "IE55";
					}
					if(IE6) {
						return "IE6";
					}
					if(IE7) {
						return "IE7";
					}
					if(IE8) {
						return "IE8";
					}
					if(IE9) {
						return "IE9";
					}
					if(IE10) {
						return "IE10";
					}
				} //isIE end
				//		    if (isFF) {
				//		        return "FF";
				//		    }
				if(isOpera) {
					return "Opera";
				}
			} //myBrowser() end
			//以下是调用上面的函数
			//		if (myBrowser() == "FF") {		    
			//		    $('.winw').show();
			//		}
			if(myBrowser() == "Opera") {
				$('.winw').show();
				$('.winw-w').show();
			}
			if(myBrowser() == "Safari") {
				$('.winw').show();
				$('.winw-w').show();
			}
			if(myBrowser() == "IE55") {
				$('.winw').show();
				$('.winw-w').show();
				alert("您的浏览器版本过低,可能有安全风险，请使用高版本浏览器");
				window.location.href = "https://support.microsoft.com/zh-cn/help/17621/internet-explorer-downloads";
			}
			if(myBrowser() == "IE6") {
				$('.winw').show();
				$('.winw-w').show();
				alert("您的浏览器版本过低,可能有安全风险，请使用高版本浏览器");
				window.location.href = "https://support.microsoft.com/zh-cn/help/17621/internet-explorer-downloads";
			}
			if(myBrowser() == "IE7") {
				$('.winw').show();
				$('.winw-w').show();
				alert("您的浏览器版本过低，可能有安全风险，请使用高版本浏览器");
				window.location.href = "https://support.microsoft.com/zh-cn/help/17621/internet-explorer-downloads";
			}
			if(myBrowser() == "IE8") {
				$('.winw').show();
				$('.winw-w').show();
				alert("您的浏览器版本过低,可能有安全风险，请使用高版本浏览器");
				window.location.href = "https://support.microsoft.com/zh-cn/help/17621/internet-explorer-downloads";
			}
			if(myBrowser() == "IE9") {
				$('.winw').show();
				$('.winw-w').show();
			}
			if(myBrowser() == "IE10") {
				$('.winw').show();
				$('.winw-w').show();
			}
		</script>
	</body>

</html>